﻿@model LeadMaster.ViewModels.ViewModelIntroducerFee

@{
    ViewBag.Title = "IntroducerFees";
}

@using (Html.BeginForm())
{
<fieldset>
<legend style="width: 220px;">Introducer Fees</legend>
@Html.DropDownListFor(model => model.IntroducerFeeID, Model.Introducers, "Please select Introducer...", new { @class = "chzn-select" })
<input type="button" value="Search" id="btnFilter" />
<div class="spacer"></div>
<table>
<tr><th>Campaign Type</th><th>Fee</th></tr>
    @for (int i = 0; i < Model.ListSectors.Count(); i++)
    {
    <tr>
    <td>
    @Model.ListSectors[i].Sector
    @Html.HiddenFor(m => m.ListSectors[i].SectorID)
    </td>
    <td>@Html.TextBoxFor(m => m.Fees[i])</td>
    </tr>
    }
</table>
<div class="spacer"></div>
<input type="submit" value="Submit" />
</fieldset>
}

<script type="text/javascript">
    $(document).ready(function () {
        $(".chzn-select").chosen();

        $("#btnFilter").click(function () {
            var url="@(Url.Action("IntroducerFees","CallCentres"))?introducerID=" + $("#IntroducerFeeID").val();
            window.location.href = url;
        });
    });
</script>